home *** CD-ROM | disk | FTP | other *** search
/ Pascal Super Library / Pascal Super Library (CW International)(1997).bin / LIBRARY / PAS_0793 / DIGSOUND.TXT < prev    next >
Text File  |  1993-08-01  |  5KB  |  74 lines

  1. ─ Fido Pascal Conference ────────────────────────────────────────────── PASCAL ─
  2. Msg  : 418 of 448                                                               
  3. From : Bernie Pallek                       1:247/128.0          24 Jul 93  11:10 
  4. To   : Matthew Mclin                                                             
  5. Subj : (2/2) Digital Sound                                                    
  6. ────────────────────────────────────────────────────────────────────────────────
  7. MM> Does anybody know the format of .MOD/.SAM/.WAV/.VOC file?
  8.  
  9. Amiga Protracker Module Format
  10.  +------++-----++-----------+
  11.  |Offset||Bytes||Description|
  12. ++------++-----++-----------+---------------------------------------------
  13. ||   0     20    Module name.  Padded with spaces until the end (or should
  14. ||                 be).  Remember to only print 20 characters.
  15. |+-Samples----------------------------------------------------------------
  16. ||  20( 0) 22    Sample Name.  Should be padded with nulls for the full
  17. ||                 length of it after the sample name.
  18. ||  42(22)  2    Sample Length.  Stored as an Amiga word which needs to be
  19. ||                 swapped on an IBM.  This word needs to be multiplied by
  20. ||                 two to get the real length.  If the initial length is
  21. ||                 greater than 8000h, then the sample is greater than 64k.
  22. ||  44(24)  1    Sample Finetune Byte.  This byte is the finetune value for
  23. ||                 the sample.  The upper four bits should be zeroed out.
  24. ||                 The lower four are the fine tune value.
  25. ||                 Value   : 0  1  2  3  4  5  6  7  8  9  A  B  C  D  E  F
  26. ||               = Finetune: 0 +1 +2 +3 +4 +5 +6 +7 -8 -7 -6 -5 -4 -3 -2 -1
  27. ||  45(25)  1    Sample Volume.  The rangle is always 0..64
  28. ||  46(26)  2    Sample Repeat.  Stored as an Amiga word.  Multiply this by
  29. ||                 two and add it to the beginning offset of the sample to
  30. ||                 get the repeat point.
  31. ||  48(28)  2    Sample Repeat Length.  Stored as an Amiga word.  Multiply
  32. ||                 this by two to get the Repeat Length.
  33. |+-------------------------------------------------------------------------
  34. ||          *** The remaining 14 or 30 samples follow this point ***
  35. ||          *** using the same format as above.  Note that the   ***
  36. ||          *** rest of this module format follows a 31 sample   ***
  37. ||          *** format, which is not different from the 15       ***
  38. ||          *** sample format except for the file offset.        ***
  39. |+-------------------------------------------------------------------------
  40. || 950      1    The Song Length in the range of 1 to 128.
  41. || 951      1    I don't know.  I was told that Noisetracker uses this byte
  42. ||                 for a restart, but I don't use Noisetracker.  Anyone
  43. ||                 have any info?
  44. || 952    128    Play Sequences 0-127.  These indicate the appropriate
  45. ||                 pattern to play at this given position.
  46. ||1080      4    If this position contains:   "M.K." or "FLT4" or "FLT8"
  47. ||                                              - the module is 31 ins.
  48. |+-Patterns----------------------------------------------------------------
  49. ||1084(0)   1    Upper 4 bits: MSB of the instrument.  Must be ORed with
  50. ||                 the LSB.  Lower 4 bits:  Upper 4 bits of the period.
  51. ||1085(1)   1    Contains the lower 8 bits of the period.
  52. ||1086(2)   1    Upper 4 bits: LSB of the instrument.  Must be ORed with
  53. ||                 the MSB.  Lower 4 bits: Special effects command.
  54. ||                 Contains a command 0-F.
  55. ||1087(3)   1    Special effects data.
  56. |+-------------------------------------------------------------------------
  57. ||          *** The number of patterns is the highest pattern    ***
  58. ||          *** number stored in the Play Sequence list.         ***
  59. |+-------------------------------------------------------------------------
  60. || Each note is four bytes long.  Four notes make up a track.  They are
  61. || stored like this:
  62. ||         0-3           4-7           8-11         12-15
  63. ||      Channel 1     Channel 2     Channel 3     Channel 4
  64. ||        16-19         20-23         24-27         28-31
  65. ||      Channel 1     Channel 2     Channel 3     Channel 4
  66. || ...and so on.
  67. ||
  68. ||                  00           00           00           00
  69. ||                  ||           ||           ||           ||
  70. ||                  /\           //           /\           \\
  71. ||  MSB of Ins.   Note        LSB Ins. Spec. Com.   Data for special
  72. ||
  73. || The samples immediately follow.
  74. ++-------------------------------------------------------------------------